package com.taotao.manage.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.taotao.dao.ItemCatDao;
import com.taotao.entity.ItemCat;
import com.taotao.entity.ItemCatExample;
import com.taotao.entity.ItemCatExample.Criteria;
import com.taotao.manage.service.ItemCatService;

@Service
public class ItemCatServiceImpl implements ItemCatService {

	@Autowired
	private ItemCatDao itemCatDao ;
	
	@Override
	public List<ItemCat> getItemCatList(long parentId) {
		ItemCatExample example = new ItemCatExample();
		Criteria criteria = example.createCriteria();
		criteria.andParentIdEqualTo(parentId);
		List<ItemCat> itemCatList = itemCatDao.selectByExample(example );
		return itemCatList;
	}

}
